package cn.wolfcode.crm.mapper;

import cn.wolfcode.crm.domain.Permission;
import cn.wolfcode.crm.query.QueryObject;

import java.util.List;
import java.util.Set;

public interface PermissionMapper {

    int deleteByPrimaryKey(Long id);

    int insert(Permission record);

    Permission selectByPrimaryKey(Long id);

    List<Permission> selectAll();

    int updateByPrimaryKey(Permission record);

    int queryForCount(QueryObject qo);

    List<Permission> queryForList(QueryObject qo);

    //根据角色id查权限
    List<Permission> queryPermissionByRoleId(Long roleId);
    //根据员工id查权限
    List<String> queryPermissionResourceByEmpId(Long id);

}